<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>
<script>
  Promise.all([
      // new Promise((resolve, reject) => {
      //   $.ajax({
      //     url: 'url1',
      //     success: function(data1) {
      //       resolve(data1);
      //     }
      //   })
      // }),
      // new Promise((resolve, reject) => {
      //   $.ajax({
      //     url: 'url2',
      //     success: function(data2) {
      //       resolve(data2);
      //     }
      //   })
      // })

      new Promise((resolve, reject) => {
        setTimeout(() => {
          resolve("result1");
        }, 2000)
      }),
      new Promise((resolve, reject) => {
        setTimeout(() => {
          resolve("result2");
        }, 1000)
      })
  ]).then(results => {
    // ["result1", "result2"]
    console.log(results);
  });
</script>
</body>
</html>